<?php
/**
 * @ClassName: EquipmentLogic
 * @Description: TODO
 * @author: ynbjykj
 * @Date: 2025-11-26 14:57
 * @Version: V1.0.0
 */

namespace app\common\logic;

use app\common\model;

class EquipmentLogic
{
    /**
     * 添加划拨记录
     * @param $device_id
     * @param $operator_type
     * @param $op_related_id
     * @param $receiver_type
     * @param $re_related_id
     * @param $remark
     * @return bool
     */
    static function addTransferRecords($device_id, $operator_type, $op_related_id, $receiver_type, $re_related_id, $remark = '')
    {
        $data = [
            'device_id' => $device_id,
            'operator_type' => $operator_type,
            'op_related_id' => $op_related_id,
            'receiver_type' => $receiver_type,
            're_related_id' => $re_related_id,
            'remark' => $remark,
            'create_time' => date_now(),
        ];

        return model\EquipmentTransferRecords::insert($data);
    }

}